package com.qianli.cashmama.trade.common.enums;

/**
 * Created with IntelliJ IDEA.
 * User: pavan
 * Date: 2019/12/12
 * Time: 下午4:33
 */
public enum AuditResultTypeEnum {
    PASS("PASS", "pass"),//通过
    REJECT("REJECT", "reject"),//拒绝
    WAITING_HIGHMARK("WAITING_HIGHMARK", "waiting highmark"),
    NEW_USER_2000("NEW_USER_2000", "NEW_USER_2000"),//新客替换成2000的产品并通过
    ;

    private String type;
    private String desc;

    AuditResultTypeEnum(String type, String desc) {
        this.type = type;
        this.desc = desc;
    }

    public String getType() {
        return type;
    }

    public AuditResultTypeEnum setType(String type) {
        this.type = type;
        return this;
    }

    public String getDesc() {
        return desc;
    }

    public AuditResultTypeEnum setDesc(String desc) {
        this.desc = desc;
        return this;
    }

    public static AuditResultTypeEnum getEnum(String type) {
        AuditResultTypeEnum auditResultTypeEnum = null;
        for (AuditResultTypeEnum enumObj : AuditResultTypeEnum.values()) {
            if (enumObj.getType().equals(type)) {
                auditResultTypeEnum = enumObj;
                break;
            }
        }
        return auditResultTypeEnum;
    }
}
